/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package carreras.datos;

import carreras.datos.connection.DBConnector;
import carreras.datos.connection.Data;
import java.sql.ResultSet;
import java.sql.SQLException;

/**
 *
 * @author fanky10
 */
public class Configuracion extends data.Data{
    public String getValue(String key,String default_value) throws SQLException{
        String query = "select valor from configuracion where clave="+DBConnector.traduce_str(key);
        ResultSet rs = db.getResultSet(query);
        while(rs.next()){
            return rs.getString("valor");
        }
        return default_value;
    }
    
}
